The scheduling of employee workshifts is typically based on work requirements, and is usually done in incremental time periods such as 15-minute periods.
For example, a supermarket may need four baggers and five cashiers between 9:15 AM and 1:15 PM, and only two baggers and three cashiers from 1:15 PM until 5:30 PM, at which time the need may again be elevated. Of course, scheduling must be satisfied from the existing pool of employees. At the same time, many rules or constraints must also be satisfied. These rules include minimum and maximum hours for a given employee, rules related to employment of minors, rules relating to break times, rules dictated by union contracts, etc.
Workforce requirements, that is, the specified need for so many workers to fill a certain time slot for a specific job or task, are typically provided either by a manager's best guess, or by some forecasting mechanism. Forecasters typically look at historical data from corresponding or similar periods from the past to produce an estimate of expected workload requirements. These requirements can then be fed to the scheduler.